<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<style>
		.div1 {
			width: 100px;
			height: 100px;
			background-color: red;
			opacity: 0.5;

		}
		.div2 {
			float: left;
			width: 100px;
			height: 100px;
			background-color: black;
			opacity: 0.5;
		}
		.div3 {
			width: 100px;
			height: 100px;
			display: inline-block;
			background-color: green;
		}
	</style>
</head>
<body>
	<div class="div1"></div>
	<div class="div2"></div>
	<div class="div3"></div>

</body>
</html>